package com.junlong0716.enjoylearning.adapter

import com.blankj.utilcode.util.TimeUtils
import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.BaseViewHolder
import com.junlong0716.enjoylearning.R
import com.junlong0716.enjoylearning.entity.StudyHistoryEntity

/**
 *@author: 巴黎没有摩天轮Li
 *@description:
 *@date: Created in 下午9:38 2018/5/13
 *@modified by:
 */
class StudyHistoryAdapter(data: ArrayList<StudyHistoryEntity>, resLayout: Int) : BaseQuickAdapter<StudyHistoryEntity, BaseViewHolder>(resLayout, data) {
    override fun convert(helper: BaseViewHolder?, item: StudyHistoryEntity?) {
        helper!!.setText(R.id.tv_title, item!!.knowledgeTitle)
        helper.setText(R.id.tv_study_date, TimeUtils.millis2String(item.knowledgeStudyDate) + "\t\t学习了")
    }

}